package my.tutorial.javacore.test.analytic;
/**
 * Java Test 6 Correct the code
 */
public class CarThread  extends Thread {
	private String brand;
	private String model;
	private double price;

	public CarThread(String brand, String model) {
		this.brand = brand;
		this.model = model;
	}

	public void run() {
		while (true) {
			System.out.println("hello my name is "+this.brand);
			try {
				Thread.sleep(300);
			} catch (InterruptedException e) {
				e.printStackTrace();
			}
		}
	}

	public static void main(String[] args) {
		new CarThread("Audi", "A6").start();
		new CarThread("BMW","GT").start();
		System.out.println("carThreads are running... ");
	}
}